package com.ruoyi.gybj.service.impl;

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.gybj.mapper.PlatformInfoMapper;
import com.ruoyi.gybj.domain.PlatformInfo;
import com.ruoyi.gybj.service.IPlatformInfoService;

/**
 * 装卸台信息Service业务层处理
 * 
 * @author ruoyi
 * @date 2025-11-19
 */
@Service
public class PlatformInfoServiceImpl implements IPlatformInfoService 
{
    @Autowired
    private PlatformInfoMapper platformInfoMapper;

    /**
     * 查询装卸台信息
     * 
     * @param id 装卸台信息主键
     * @return 装卸台信息
     */
    @Override
    public PlatformInfo selectPlatformInfoById(Long id)
    {
        return platformInfoMapper.selectPlatformInfoById(id);
    }

    /**
     * 查询装卸台信息列表
     * 
     * @param platformInfo 装卸台信息
     * @return 装卸台信息
     */
    @Override
    public List<PlatformInfo> selectPlatformInfoList(PlatformInfo platformInfo)
    {
        return platformInfoMapper.selectPlatformInfoList(platformInfo);
    }

    /**
     * 新增装卸台信息
     * 
     * @param platformInfo 装卸台信息
     * @return 结果
     */
    @Override
    public int insertPlatformInfo(PlatformInfo platformInfo)
    {
        platformInfo.setCreateTime(DateUtils.getNowDate());
        return platformInfoMapper.insertPlatformInfo(platformInfo);
    }

    /**
     * 修改装卸台信息
     * 
     * @param platformInfo 装卸台信息
     * @return 结果
     */
    @Override
    public int updatePlatformInfo(PlatformInfo platformInfo)
    {
        platformInfo.setUpdateTime(DateUtils.getNowDate());
        return platformInfoMapper.updatePlatformInfo(platformInfo);
    }

    /**
     * 批量删除装卸台信息
     * 
     * @param ids 需要删除的装卸台信息主键
     * @return 结果
     */
    @Override
    public int deletePlatformInfoByIds(Long[] ids)
    {
        return platformInfoMapper.deletePlatformInfoByIds(ids);
    }

    /**
     * 删除装卸台信息信息
     * 
     * @param id 装卸台信息主键
     * @return 结果
     */
    @Override
    public int deletePlatformInfoById(Long id)
    {
        return platformInfoMapper.deletePlatformInfoById(id);
    }
}
